﻿var bmHelp = {
    wnd: null,
    hide: function() {
        if (bmHelp.wnd) {
            try {
                bmHelp.wnd.close();
            }
            catch (e) {
            }
            bmHelp.wnd = null;
        }
    },
    show: function(url) {
        if (bmHelp.wnd) {
            try {
                bmHelp.wnd.location = url;
            }
            catch (e) {
                bmHelp.wnd = window.open(url);
            }
        }
        else {
            bmHelp.wnd = window.open(url);
        }
    },
    getIsVisible: function() {
        if (bmHelp.wnd != null) {
            try {
                var s = bmHelp.wnd.status;
                return true;
            }
            catch (e) {
                return false;
            }
        }
        return false;
    }
}